The invention relates generally to the field of estimating the format of an image (portrait or landscape). Additionally, the invention relates generally to the field of estimating the orientation (selection of the image side corresponding to the xe2x80x9cupxe2x80x9d direction relative to the photographer.)
Conventional consumer cameras (both film and digital) capture an image having a rectangular imaging area that has one dimension longer than the other dimension. For cameras using 35 mm film, the horizontal dimension of the imaging area is about 36 mm and the vertical dimension of the imaging area is about 24 mm.
Generally, when a camera is in the upright position, the longer dimension of the imaging area is horizontal. If a photographer captures an image with the camera in the upright position, the top of the image generally corresponds to one of the two sides of the imaging area having a longer dimension. Images that have the top of the image corresponding to one of its longer two sides are referred to as xe2x80x9clandscape formats.xe2x80x9d However, it is common for the photographer to rotate the camera 90 degrees to capture the photograph so as to achieve a more pleasing composition for certain subjects. Where this is the case, the top of the image then corresponds to one of the two sides with a shorter dimension; and the resulting image is referred to as having a xe2x80x9cportrait format.xe2x80x9d
Determining whether an image is a portrait or a landscape has many possible practical implications. For example, auto-albuming applications, where album page layouts are automatically designed, require an allocation of page space that is related to whether an image is a portrait or a landscape. In addition, certain algorithms are used in an attempt to determine the orientation of an image based upon more than one frame in a consumer order. Having knowledge of whether a particular image within an order is a portrait or a landscape can be critical to these algorithms since it is very likely that all landscape scenes within a consumer order have a common orientation.
If the image orientation (i.e., which one of the four rectangular sides is xe2x80x9cupxe2x80x9d from the photographer""s point of view) is known, then the portrait and landscape format is known. Knowledge of image orientation allows for the correct orientation of an image on an output display.
U.S. Pat. No. 5,642,443, issued Jun. 24, 1997 to Goodwin et al., entitled xe2x80x9cWhole Order Orientation Method and Apparatusxe2x80x9d describes a method of considering an entire set of images in a consumer""s order to determine the orientation of an entire order. A statistical estimate of orientation is generated for each image in the set. A statistical estimate for the entire order is derived based upon the estimates for individual images in the set. Goodwin et al teach deriving relevant probabilities from spatial distributions of colors within the image. Goodwin et al must view an entire order of images rather than a single image. There are applications that only contain one image that Goodwin et al will be unable to correctly orient.
Also, U.S. Pat. No. 4,870,694, issued Sep. 26, 1989 to Takeo, entitled xe2x80x9cMethod of Determining Orientation of Imagexe2x80x9d describes a method of determining the orientation of an image that contains a representation of a human body. The position of the human is used as a clue to the orientation of the image. Takeo is primarily applicable to radiographic applications as used in hospitals or medical clinics. It is unlikely a broad-based consumer application, because it depends on certain constraints, such as requiring a human figure within the image.
Additionally, U.S. Pat. No. 6,011,585, issued Jan. 4, 2000 to Anderson, entitled xe2x80x9cApparatus and Method for Rotating the Display Orientation of a Captured Imagexe2x80x9d describes a method of determining image format and orientation based upon a sensor present in the camera at the time of image capture. However, if a sensor is not present in a particular camera or image-capturing device, the method of Anderson is not useful. The approach described by Anderson has the further disadvantage of requiring additional apparatus in the camera. Moreover, an image processing unit or operation will be unable to perform correct orientation unless the particular camera contained the additional apparatus.
Lutton et al. (in xe2x80x9cContribution to the Determination of Vanishing Points Using Hough Transform,xe2x80x9d IEEE Trans. Pattern Analysis and Machine Intelligence, Vol. 16, No. 4, pp. 430-438, Apr. 1994) attempts to detect the vertical direction of an image. The Lutton et al. article teaches one to select the direction that is orthogonal to the most directions in the scene. The implicit assumption is that the scene will contain many horizontal lines. However, this is not always the case. In addition Lutton determines a vertical direction based on an analysis of all lines in the scene, which can be time consuming. Also, this method must consider a slew of random image lines which may skew the result. Therefore, an image may contain format errors.
Consequently, there is a need for overcoming the above-described drawbacks. More specifically; a need exists for an improved method for accurately estimating the format and orientation of a digital image without using additional apparatus or introducing error into an algorithm.
The need is met according to the present invention by providing a method of determining the vertical axis of an image, including the steps of: detecting a set of vanishing points related to the image; selecting a vanishing point based on a predetermined criteria; and identifying the vertical axis with the selected vanishing point.
One advantage of the present invention is increasing the statistical probability of accurately determining the orientation of an image. An image can be thought of as having a format, i.e., xe2x80x9clandscape,xe2x80x9d or xe2x80x9cportraitxe2x80x9d; or an orientation, (i.e., an xe2x80x9cupxe2x80x9d direction).
These and other aspects, objects, features and advantages of the present invention will be more clearly understood and appreciated from a review of the following detailed description of the preferred embodiments and appended claims, and by reference to the accompanying drawings.